package com.wanxi.duotai;

public class Test {
    public static void main(String[] args) {
        AnimalOperator animalOperator = new AnimalOperator();
        Animal animal = new Cat();
//        Cat cat = (Cat) animal;
//        cat.run();
        Dog dog = (Dog) animal;
        dog.walk();
//        animalOperator.userWho(animal);
//        Cat cat=new Cat();
//        Dog dog=new Dog();
//        Animal cat=new Cat("cat");
//        cat.sleep(cat);
//        Cat cat = new Cat();
//        cat.setName("cat");
//        cat.sleep(cat);
//        Dog dog = new Dog();
//        dog.setName("dog");
//        dog.sleep(dog);
//        cat.height = 1;
//        cat.run();
//        System.out.println(cat.height);
//        cat.sleep();
//        Animal dog = new Dog();
//        dog.sleep();
//        System.out.println(dog.height);
    }
}
